#pragma once

#ifndef __ASSEMBLY__
#ifdef __KERNEL__

#include <asm/alternative.h>
#include <asm/cpufeature.h>

static inline void cpu_relax(void)
{
	asm volatile("yield" ::: "memory");
}

#define ARCH_HAS_PREFETCHW
static inline void prefetchw(const void *ptr)
{
	asm volatile("prfm pstl1keep, %a0\n" : : "p" (ptr));
}

#endif

#endif /* __ASSEMBLY__ */
